package cn.com.lightech.led_g5g_g.biz;


import cn.com.lightech.led_g5g_g.gloabal.LedChannel;
import cn.com.lightech.led_g5g_g.model.LocalLedChannelModel;

/**
 * Created by PC on 2017/5/20.
 */

public class LedChannelBiz {

    private LocalLedChannelModel channelModel = new LocalLedChannelModel();


    public int getChannel() {
        int localChannel = channelModel.getLocalChannel();
        switch (localChannel) {
            case LedChannel.Channel_A:
                return LedChannel.Channel_A;
            case LedChannel.Channel_B:
                return LedChannel.Channel_B;
            default:
                return LedChannel.Channel_B;
        }

    }


    public void setChannel(int channel ){
        int value;
        switch (channel) {
            case LedChannel.Channel_A:
                value= LedChannel.Channel_A;
                break;
            case LedChannel.Channel_B:
                value= LedChannel.Channel_B;
                break;
            default:
                value= LedChannel.Channel_B;
        }
        channelModel.setLocalChannel(value);

    }


}
